<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Food manage</title>

</head>
<body>

	<jsp:include page="../../common/bar.jsp"></jsp:include>

	<div class="container-fluid">
		<div class="row"></div>
		<div class="col-sm-1 col-md-1 sidebar">
			<ul class="nav nav-sidebar">
				<li><a data-toggle="tab">Home<span class="sr-only">(current)</span></a></li>
				<li class="active" id="m_manager"><a href="#menumanager"
					data-toggle="tab">Food Manage<span class="sr-only">(current)</span></a></li>
			</ul>
		</div>

		<div class="tab-content">

			<div
				class="col-sm-10 col-sm-offset-1 col-md-11 col-md-offset-1 main tab-pane active"
				id="menumanager">
				<h2 class="sub-header">Menu List</h2>
				<button type="button" class="btn btn-primary add_btn"
					data-toggle="modal" data-target="#addModal">Add Food</button>


				<div class="table-responsive">
					<table class="table table-striped">
						<thead>
							<tr>
								<th>Id</th>
								<th>Name</th>
								<th>Price</th>
								<th>Img</th>
								<th>Type</th>
								<th>Modify</th>
								<th>Delete</th>
							</tr>
						</thead>
						<tbody id="menus">

						</tbody>
					</table>
				</div>
			</div>


		</div>

	</div>


	﻿

	<jsp:include page="../../common/img.jsp"></jsp:include>


	<div class="modal fade" id="addModal" tabindex="-1" role="dialog"
		aria-labelledby="addLabel">
		<div class="modal-dialog" role="document">
			<div class="modal-content">
				<div class="modal-header">
					<button type="button" class="close" data-dismiss="modal"
						aria-label="Close">
						<span aria-hidden="true">&times;</span>
					</button>
					<h4 class="modal-title" id="addLabel">Add Menu</h4>
				</div>
				<div class="modal-body">
					<form enctype="multipart/form-data">
						<label for="name">Name</label> <input type="text"
							class="form-control" id="add_name" placeholder="pls input name">

						<br> <label for="name">Price</label> <input type="number"
							step="0.01" class="form-control" placeholder="pls input price"
							id="add_price"> <br> <label class="control-label">Image</label>
						<input id="add_img" name="add_img" type="file"
							class="file btn btn-default" data-show-preview="false"
							style="width: 100%"> <br> <label
							class="control-label">Type</br></label> <select id="add_type"
							class="selectpicker">
							<option value="8a5e9d3d5dde5982015dde5985cb0001">Staple
								food</option>
							<option value="8a5e9d3d5dde5982015dde59858f0000">Drinks</option>
							<option value="8a5e9d3d5dde5982015dde5985ce0002">Snack</option>
							<option value="8a5e9d3d5dde5982015dde5985d00003">Set
								meal</option>
						</select>
					</form>
				</div>
				<div class="modal-footer">
					<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
					<button type="button" id="add_menu" class="btn btn-primary">Add
						menu</button>
				</div>
			</div>
		</div>
	</div>


	<div class="modal fade" id="updateModal" tabindex="-1" role="dialog"
		aria-labelledby="addLabel">
		<div class="modal-dialog" role="document">
			<div class="modal-content">
				<div class="modal-header">
					<button type="button" class="close" data-dismiss="modal"
						aria-label="Close">
						<span aria-hidden="true">&times;</span>
					</button>
					<h4 class="modal-title" id="addLabel">Update Menu</h4>
				</div>
				<div class="modal-body">
					<form enctype="multipart/form-data">

						<input type="hidden" class="form-control" id="update_id">
						<input type="hidden" class="form-control" id="update_imgpath">

						<label for="name">Name</label> <input type="text"
							class="form-control" id="update_name"
							placeholder="pls input name"> <br> <label for="name">Price</label>
						<input type="number" step="0.01" class="form-control"
							placeholder="pls input price" id="update_price"> <br>
						<label class="control-label">Image</label> <input id="update_img"
							name="update_img" type="file" class="file btn btn-default"
							data-show-preview="false" style="width: 100%"> <br>
						<label class="control-label">Type</br></label> <select id="update_type"
							class="selectpicker">
							<option value="8a5e9d3d5dde5982015dde5985cb0001">Staple
								food</option>
							<option value="8a5e9d3d5dde5982015dde59858f0000">Drinks</option>
							<option value="8a5e9d3d5dde5982015dde5985ce0002">Snack</option>
							<option value="8a5e9d3d5dde5982015dde5985d00003">Set
								meal</option>
						</select>


					</form>
				</div>
				<div class="modal-footer">
					<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
					<button type="button" id="update_menu" class="btn btn-primary">Update
						menu</button>
				</div>
			</div>
		</div>
	</div>



	<script type="text/javascript" src="../../js/component/food.js"></script>
	<script type="text/javascript" src="../../js/food.js"></script>

</body>


</html>